Ext.define('PackageManager.store.PackageStoreFull', {
    extend: 'Ext.data.Store',
    model: 'PackageManager.model.PackageModelFull',

    autoLoad: true,
    autoSync: true,

    proxy: {
        type: 'ajax',

        api: {
            read: window.location.href + '/fullpackage/read',
            update: window.location.href + '/fullpackage/update',
            create: window.location.href + '/fullpackage/update1'
        }
    },

    onProxyLoad: function (aOperation) {
        var iResult = aOperation.resultSet.records;
        console.log('Full Store onProxyLoad');
        componentStore = Ext.StoreManager.lookup('ComponentStore');
        packageStore = Ext.StoreManager.lookup('PackageStore');
        staticDataStore = Ext.StoreManager.lookup('StaticDataStore');


        componentStore.loadData(iResult[0].raw.components);
        staticDataStore.loadData(iResult[0].raw.staticDatas);

        packageStore.loadData(iResult);

        console.log(this);
    }

});